Modeling significant locations

ABSTRACT

Techniques for modeling significant locations are described. A significant location can be a location that is significant to a user of a mobile device for a variety of reasons. The mobile device can determine that a place or region is a significant location upon determining that, with sufficient certainty, the mobile device has stayed at the place or region for a sufficient amount of time. The mobile device can construct a state model that is an abstraction of one or more significant locations. The state model can include states representing the significant locations, and transitions representing movement of the mobile device between the locations. The mobile device can use the state model to provide predictive user assistance.

CROSS REFERENCE TO RELATED APPLICATIONS

This application is a continuation of and claims priority to U.S. patent application Ser. No. 14/020,689, filed Sep. 6, 2013, which is a non-provisional of and claims priority to U.S. Provisional Patent Application No. 61/832,741, filed on Jun. 7, 2013, the entire contents of each of which are hereby incorporated by reference.

TECHNICAL FIELD

This disclosure relates generally to location-based services.

BACKGROUND

Many electronic devices have location-based functions. For example, a mobile device can estimate a location of the mobile device using a satellite navigation system (e.g., global positioning system or GPS) or a cellular communications system. The mobile device can perform various tasks that are location specific. For example, a map application executing on the mobile device can cause the mobile device to display a map. A marker on the map can indicate a current location of the mobile device. Upon receiving a user input selecting the marker, the mobile device can display points of interests, e.g., restaurants or gas stations, that are close to the current location. Upon receiving a user input specifying a destination, the mobile device can display a route from the current location to the destination, and an estimated time of arrival based on traffic information on the route.

SUMMARY

Techniques for modeling significant locations are described. A significant location can be a location that is significant to a user of a mobile device for a variety of reasons. The mobile device can determine that a place or region is a significant location upon determining that, with sufficient certainty, the mobile device has stayed at the place or region for a sufficient amount of time. The mobile device can construct a state model that is an abstraction of one or more significant locations. The state model can include states representing the significant locations, and transitions representing movement of the mobile device between the locations. The mobile device can use the state model to provide predictive user assistance.

The features described in this specification can be implemented to achieve one or more advantages. A mobile device can learn a movement pattern of the mobile device, and adapt itself to that movement pattern. Using the techniques described in this specification, a mobile device can implement predictive user assistance. The mobile device implementing predictive user assistance can provide the assistance based on the movement pattern without requiring additional user input. Accordingly, a user of the mobile device may have a better experience using services, especially location-based services, of the mobile device. For example, the mobile device can determine that a user usually goes from home to work at 8:00 am on weekdays and from home to a gymnasium at 8:00 am on weekends. Upon being turned on shortly before 8:00 am, on weekdays, the mobile device can automatically display traffic information on a route from home to work; whereas on weekends, the mobile device can automatically display traffic information on a route from home to the gymnasium.

The details of one or more implementations of modeling significant locations are set forth in the accompanying drawings and the description below. Other features, aspects, and advantages of modeling significant locations will become apparent from the description, the drawings, and the claims.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a diagram illustrating an exemplary implementation of predictive user assistance.

FIG. 2 is a diagram illustrating exemplary techniques of determining location clusters.

FIG. 3 is a diagram illustrating exemplary techniques of identifying significant locations based on location clusters.

FIG. 4 is a diagram illustrating an exemplary state model determined based on the location clusters.

FIG. 5 is a diagram illustrating incremental changes to the state model.

FIG. 6A is a diagram illustrating determining a transition probability density between exemplary states.

FIG. 6B is diagram illustrating determining an entry probability density of an exemplary state.

FIGS. 7A, 7B, and 7C are block diagrams illustrating components of an exemplary mobile device implementing predictive user assistance.

FIG. 8 is a flowchart illustrating an exemplary procedure of generating a state model.

FIG. 9 is a flowchart illustrating an exemplary procedure of predicting a future location.

FIG. 10 is a block diagram illustrating an exemplary device architecture of a mobile device implementing the features and operations of FIGS. 1-9.

FIG. 11 is a block diagram of an exemplary network operating environment for the mobile devices implementing the features and operations of FIGS. 1-9.

Like reference symbols in the various drawings indicate like elements.

DETAILED DESCRIPTION Exemplary Predictive User Assistance

FIG. 1 is a diagram illustrating an exemplary implementation of predictive user assistance. Exemplary mobile device 102 can utilize past movements of mobile device 102 to predict a future location of mobile device 102. Mobile device 102 can then adapt behavior of mobile device 102 to perform services that are specific to the predicted future location.

Mobile device 102 can use machine learning and data mining techniques to learn the past movement of mobile device 102. The past movement can be recorded as significant locations visited by mobile device 102 and movement of mobile device 102 between the significant locations. Mobile device 102 can determine that a place or region is a significant location upon determining that, with sufficient certainty, mobile device 102 has stayed at the place or region for a sufficient amount of time. The amount of time can be sufficient if it satisfies various criteria, for example, when the amount of time satisfies a time length threshold (e.g., X hours) or a frequency threshold (e.g., X minutes per day, Y number of days per week). Records of movement of mobile device 102 can include a measured or calculated time of entry into each significant location and a measured or calculated time of exit from each significant location. A significant location can be associated with multiple entries and exits.

In addition to significant locations, the records of movement can include transitions between the significant locations. Each transition from a first significant location to a second significant location can be associated with a transition begin timestamp indicating a time mobile device 102 leaves the first significant location and a transition end timestamp indicating a time mobile device 102 enters the second significant location.

Mobile device 102 can represent the records of movement as state model 104. State model 104 can include states (e.g., state 106 and other states) each representing a significant location, and transitions (e.g., transition 107 and other transition between the states) each representing a movement of mobile device 102 between significant locations. Additional details of determining state model 104 are described below in reference to FIG. 2-5.

Based on state model 104, mobile device 102 can determine (1) a transition probability density that, at a given time, mobile device 102 moves from a given significant location to each other significant location, or (2) an entry probability density that mobile device 102 enters a significant location from a previously unknown or unrepresented location. A pattern analyzer of mobile device 102 can determine a daily, weekly, monthly, or annual movement pattern of mobile device 102 using state model 104. A predictive engine of mobile device 102 can use transition probability density (or entry probability density) and the movement pattern to forecast a significant location that mobile device 102 will enter (or stay) at a future time. Mobile device 102 can then use the forecast to provide predictive user assistance, e.g., to assist the user to plan for a future event.

In the example of FIG. 1, mobile device 102 can determine current location 108 using a location determination subsystem of mobile device 102. Mobile device 102 can determine current time 110. Based on the current location, current time, and the probabilities and patterns of state model 104, mobile device 102 can determine that a most likely location of mobile device 102 at a given time in the future is a significant location represented by state 106. Mobile device 102 can then perform a user-assistance function corresponding to the significant location, or corresponding to a transition from the current location to the significant location. For example, upon being turned on or unlocked, mobile device 102 can provide for display alert 112 on a display surface of mobile device 102. Alert 112 can include user assistance information 116. User assistance information 116 can include, for example, a route from the current location to the likely future location, and traffic information along the route. Mobile device 102 can provide for display alert 112 and user assistance information 116 automatically, without requesting a user to input the likely future location as a destination.

In some implementations, mobile device 102 can provide a label associated with the likely future location. The label can be an address or a name of a point of interest pre-specified by a user or determined by mobile device 102 through reverse geocoding or through semantic analysis of movements of mobile device 102. For example, mobile device 102 can determine that a first location is likely to be a home and a second location is likely to be a work place. Accordingly, mobile device 102 can use the terms “home” and “work” in user assistance information 116.

Exemplary Techniques of Constructing a State Model

FIG. 2 is a diagram illustrating exemplary techniques of determining location clusters. Exemplary mobile device 102 (of FIG. 1) can use the learning techniques to determine state model 104 (of FIG. 1).

Mobile device 102 can sequentially trace location data through time (T). Sequentially tracing location data can be performed by piggybacking on another application to avoid or reduce cost of location data collection. For example, mobile device 102 can collect the location data when another service requests location from a location determination subsystem of mobile device 102. Accordingly, collecting the location data can be “free” without having to activate the location determination subsystem solely for determining a movement pattern of mobile device 102.

Mobile device 102 can collect locations 202, 204, 206, 208, 210, and 212 over time T. Collecting the locations can be on-going operations. Locations older than a specified period can be purged. The period can be specified by user preference or privacy policies. Locations 202, 204, 206, 208, 210, and 212 can each include latitude, longitude, and altitude coordinates and being associated with a timestamp indicating a time the corresponding location is collected.

Mobile device 102 can determine that some of locations 202, 204, 206, 208, 210, and 212 belong to location clusters that may indicate a significant location. Mobile device 102 can determine that a location cluster is formed upon determining that (1) at least a pre-specified threshold number (e.g., two) of consecutive locations are collected; (2) a time span of the consecutive locations satisfies a pre-specified threshold time window; and (3) these locations are identical, indicating that mobile device 102 is stationary, or sufficiently close to one another, indicating that mobile device 102 is located in a sufficiently small and defined area during the time the locations are collected.

For example, mobile device 102 can determine two location clusters, location cluster 218 and location cluster 220, over time T. Location cluster 218 can include locations 202, 204, and 206, which are collected over a time period [T1, T2] that is longer than a threshold time window (e.g., a time window of 45 minutes). Mobile device 102 can determine that location cluster 218 includes locations 202, 204, and 206 upon determining that a variance of locations 202, 204, and 206 is low enough to satisfy a variance threshold. Likewise, location cluster 220 can include locations 210 and 212, which are collected within time period [T3, T4]. Mobile device 102 can determine that location cluster 220 includes locations 210 and 212 upon determining that a variance of locations 210 and 212 satisfies the variance threshold.

An outlier detection mechanism can filter out locations that do not belong to clusters. For example, mobile device 102 can determine that location 208 is different from location 206 and location 210 (e.g., the distance between location 206 and 208 and the distance between location 208 and location 210 exceeds a threshold). In addition, mobile device 102 can determine that no other locations are (1) collected within the threshold time window before or after location 208 and (2) geographically close to location 208. In response, mobile device 102 can determine that location 208 is an outlier and discard location 208. In addition, if a location in a time period is significantly different from many other locations in the time period, mobile device 102 can discard the different location as an outlier and determine the location cluster using other locations in the time window. Mobile device 102 can use location clusters 218 and 220 to determine significant locations and states of state model 104.

FIG. 3 is a diagram illustrating exemplary techniques of identifying significant locations based on location clusters. Using the techniques described above in reference to FIG. 2, mobile device 102 can identify location clusters 218, 220, 302, and 303. Mobile device 102 can determine significant locations 304, 306, and 308 based on location clusters 218, 220, 302, and 303.

Mobile device 102 can determine each of significant locations 304, 306, and 308 based on location clusters 218, 220, 302, and 303 using the locations in each of location clusters 218, 220, 302, and 303. Determining significant locations 304, 306, and 308 can be based on recursive filter with a constant gain. Details of determining significant locations 304, 306, and 308 are provided below in the next paragraph. Each of significant locations 304, 306, and 308 can include latitude, longitude, and optionally, altitude coordinates. Each of significant locations 304, 306, and 308 can be associated with one or more location clusters. For example, signification location 304 can correspond to location cluster 218 in time period [T1, T2] and location cluster 303 during time period [T7, T8]. Location in location cluster 218 and location cluster 303 can be identical. The length of time period [T1, T2] and time window [T7, T8] can be same or different.

Mobile device 102 can have an initial state model at time T2. At time T2+k, mobile device 102 can receive incremental location data, where k is a difference between time T2 and the time the additional location data are received (in this example, k=T7−T2). Mobile device 102 can use the incremental location data to determine significant location 304 for use in the state model. Mobile device 102 can determine that location cluster 218 corresponds to latitude and longitude coordinates X1. Mobile device 102 can determine that location cluster 303 corresponds to latitude and longitude coordinates X2. Mobile device 102 can determine that a distance between X1 and X2 satisfies a threshold. In response, mobile device 102 can determine that location cluster 218 and location cluster 303 belong to a same location (significant location 304). Mobile device 102 can then add location cluster 303 to significant location 304 using constant gain filter as shown below in filter 1. (e.g., a function of sampling data, e.g., 5, 6, 7, may not be same for all clusters)

$\begin{matrix} {\frac{{X\; 2} + {\alpha\; X\; 1}}{1 + \alpha},{{{where}\mspace{14mu}\alpha} \geq 1}} & (1) \end{matrix}$

The value α in filter 1 (e.g., 5, 6, 7) can be a function of sampling data and may be same for all location clusters or different for each location cluster.

Each of significant locations 304, 306, and 308 can be associated with one or more entry timestamps and one or more exit timestamps. Each entry timestamp can correspond to a time associated with a first location in a location cluster. For example, a first entry timestamp associated with significant location 304 can be a timestamp associated with location 202, which is the first location of location cluster 218. A second entry timestamp associated with significant location 304 can be a timestamp associated with a first location in location cluster 303. Likewise, each exit timestamp can correspond to a time associated with a last location in a location cluster. For example, a first exit timestamp associated with significant location 304 can be a timestamp associated with location 206, which is the last location of location cluster 218. A second entry timestamp associated with significant location 304 can be a timestamp associated with a last location in location cluster 303.

Each of significant locations 304, 306, and 308 can be associated with a label. The label can be designated by a user (e.g., “Home,” “Gym,” or “Work”), or automatically determined by mobile device 102 through reverse geocoding. In some implementations, the label can be derived from a semantic analysis of a pattern of the time of day and day of week of each location cluster associated with the significant locations. The semantic analysis can be based on behaviors natural to human beings. Mobile device 102 can be programmed to apply pre-determined patterns that reflect the human behavior. The behavior can include, for example, every human being needs to sleep for some time. The time for sleeping can be a time mobile device 102 is strictly stationary. A user sleeps eight hours a day and eating dinner at home is likely to spend X hours (e.g., 10-12 hours) at home on weekdays, and Y hours on weekends. A user can be at work Monday through Friday for regular hours. Mobile device 102 can leverage these patterns to determine that a significant location as “home” where (1) mobile device 102 spends more than a first threshold number of hours (e.g., 60 hours) per week; (2) mobile device 102 records most entries and exits; and (3) those entries and exists indicate that mobile device stays at least a second threshold number of hours (e.g., eight hours) per day.

For example, mobile device 102 can determine that each location cluster associated with significant location 304 corresponds to a time period designated as evening during weekdays (e.g., from 7:00 pm to 8:00 am next day). Mobile device 102 can then designate significant location 304 as “home” and provide the designation as a label for significant location 304.

Mobile device 102 can determine transitions from one significant location to another. For example, mobile device 102 can determine that, on a given weekday, mobile device 102 transitions (312) from significant location 304 (“Home”) to significant location 308 (“Work”) between time T2 and time T3. Mobile device 102 can associate the transition with a transition begin timestamp (e.g., T2) and a transition end timestamp (e.g., T3). Mobile device 102 can construct state model 104 based on significant locations 304, 306, and 308 and transitions 312, 314, and 316. Details of state model 104 are described below in reference to FIG. 4.

FIG. 4 is a diagram illustrating exemplary state model 104 determined based on the location clusters. State model 104 can be an n-th order autoregressive process (e.g., first order autoregressive process) depicting states and state transitions where a transition into a state q is conditioned by a previous state r. Accordingly, state model 104 can capture an entire history of states and transitions before a given state. The state and state transitions can be an abstraction of movement of mobile device 102 among significant locations. Compared to a conventional Gauss-Markov model, state model 104 can be a sufficient model, retaining stochastic properties of the state transitions using distribution function in time and duration.

State model 104 can include states 106, 402, and 404. States 106, 402, and 404 can correspond to significant locations 304, 308, and 306, respectively. Mobile device 102 can determine significant locations 304, 308, and 306 based on location clusters 218, 220, 302, and 303, as described above in reference to FIG. 3. Each of states 106, 402, and 404 can be a representation of significant locations 304, 308, and 306, respectively.

State model 104 can include multiple transitions from each state to each other state. The transitions can include, for example, transition 406 from state 106 to state 402, and transition 408 from state 106 to state 402. In state model 104, each transition from state 106 to state 402 can correspond to a transition from a location cluster of significant location 304 to a location cluster of significant location 308. For example, transition 406 can represent transition 312 from location cluster 218 of significant location 304 to location cluster 220 of significant location 308. Transition 408 can represent a transition from location cluster 303 of significant location 304 to a next location cluster of significant location 308.

Each of transitions 406 and 408 can be associated with a transition begin timestamp and a transition end timestamp. Each transition begin timestamp can be a time that mobile device 102 leaves significant location 304 represented by state 106. For example, the transition begin timestamp of transition 406 can be Tuesday, 7:00 am; the transition begin timestamp of transition 408 can be Wednesday, 7:00 am. Each transition end timestamp can be a time that mobile device 102 enters significant location 308 represented by state 402. For example, the transition end timestamp of transition 406 can be Tuesday, 9:00 am; the transition end timestamp of transition 408 can be Wednesday, 9:00 am.

Each state of state model 104 can be associated with one or more state entry timestamps and one or more state exit timestamps. For example, a first state entry timestamp for state 106 can be a time associated with a first location (location 202) of mobile device 102 located in location cluster 218 of significant location 304. A first state exit timestamp can be a time associated with a last location (location 206) of mobile device 102 located in location cluster 218 of significant location 304. The first state entry timestamp and the first state exit timestamp can define first dwell time 412 of mobile device 102 staying at state 106. A second state entry timestamp for state 106 can be a time associated with a first location of mobile device 102 located in location cluster 303 of significant location 304. A second state exit timestamp can be a time associated with a last location of mobile device 102 in location cluster 303 of significant location 304. The second state entry timestamp and the second state exit timestamp can define second dwell time 414 of mobile device 102 staying at state 106.

FIG. 5 is a diagram illustrating incremental changes to state model 104. State model 104 can have a variable topology, allowing incremental addition of new states and deletion of obsolete states.

Mobile device 102 can determine new state 502. For example, mobile device 102 can determine that a series of location readings indicate that mobile device 102 is located at a place for a sufficiently long duration that, with sufficient certainty, that the place is a significant location. Mobile device 102 can determine that the significant location is not represented in state model 104. In response, mobile device 102 can create new state 502, and add (504) new state 502 to state model 104. Mobile device 102 can add transitions to state 502 based on a last significant location visited by mobile device 102 prior to visiting state 502. Mobile device 102 can associate state 502 with a state entry timestamp of a first location reading indicating mobile device 102 is located at the significant location of state 502. Mobile device 102 can associate state 502 with a state exit timestamp of a last location reading indicating mobile device 102 is at the significant location represented by state 502 before mobile device 102 enters another significant location. Mobile device 102 can add transitions from state 502 based on the next significant location visited by mobile device 102 and represented in state model 104.

In addition to adding states, mobile device 102 can periodically remove states from state model 104. Mobile device 102 can determine that, for a sufficiently long time (e.g., exceeding an X day or week threshold), mobile device 102 has not visited a significant location represented by state 404. Accordingly, mobile device 102 can remove (506) state 404 from state model 104. Removing state 404 can include removing transitions into state 404 and transitions from state 404.

Mobile device 102 can use state model 104 to predict a future location of mobile device 102. Predicting the future location can be based at least in part on a current location of mobile device 102. The current location can be “in state,” where the current location is represented by a state of state model 104. Upon determining that the current location is in state, mobile device 102 can predict the future location based on transition probability densities between states. The current location can be “out of state,” where the current location is not represented by a state of state model 104. Upon determining that the current location is out of state, mobile device 102 can predict the future location based on entry probability densities of entering a state of state model 104 from the current location. Details on determining the transition probability densities and entry probability densities are described below in reference to FIGS. 6A and 6B.

FIG. 6A is a diagram illustrating determining a transition probability density 602 between exemplary states 106 and 402. Transition probability density 602 can indicate a probability distribution of mobile device 102 transitions from state 106 to state 402 of state model 104. Mobile device 102 can determine transition probability density 602 upon receiving a request to predict a future location of mobile device 102. The request can be associated with a current time and a future time. At the current time, mobile device 102 can be located at a significant location corresponding to state 106. The future time can be a point in time or a time window.

Transition probability density 602 can be a distribution over a time period, e.g., [Ta, Tb], where Ta is a starting time, and Tb is an ending time of the time period. The time period [Ta, Tb] can be a window of forecast. In some implementations, the starting time Ta can correspond to the current time, or the current time with a bias (e.g., X minutes before or after the current time); the ending time Tb can correspond to the future time, or the future time with a bias (e.g., Y minutes before or after the future time). In some implementations, the starting time Ta and ending time Tb can correspond to a beginning and an ending of a time window (e.g., a day or a week), respectively.

Mobile device 100 can determine transition probability density 602 based on past transitions of mobile device 100 from state 106 to state 402. At a given time between Ta and Tb, (1) more transitions from state 106 to state 402 in the past at the given time can correspond to a higher probability density value; (2) more certainty on the transitions in the past at the given time can correspond to a higher probability density value; and (3) a more stable pattern of transitions in the past at the given time can correspond to a higher probability density value.

For example, t0 corresponds to 8:00 am, and t1 corresponds to 3:00 pm. In the past, and as recorded in state model 104, X number of transitions occurred between state 106 and state 402 between 7:00 am and 9:00 am; and Y number of transitions occurred between 2:00 pm and 4:00 pm. If X is greater than Y, t0 can correspond to comparatively higher probability density value 604, whereas t1 can correspond to comparatively lower probability density value 606.

In addition, the certainty of the transitions can be relevant. If a mean time of the transition start timestamps of the X transitions is closer to t0 than a mean time of the transition start timestamps of the Y transition is closer to t1, t0 can correspond to comparatively higher probability density value 604, whereas t1 can correspond to comparatively lower probability density value 606. If a variance of the transition start timestamps of the X transitions is smaller than a variance of the transition start timestamps of the Y transitions, t0 can correspond to comparatively higher probability density value 604, whereas t1 can correspond to comparatively lower probability density value 606.

In addition, stability of patterns of transitions in the past can be relevant. Mobile device 102 can determine a pattern of movement based on time. For example, mobile device 102 can determine, based on transitions in state model 104, that movement of mobile device 102 follows a weekly pattern. On week days, mobile device 102 transitions from state 106 to state 402 between 7:00 am and 9:00 am. On weekends, mobile device 102 transitions from state 106 to state 402 between 2:00 pm and 4:00 pm. Based on this identified weekly pattern, mobile device 102 can associate a comparatively higher probability density value 604 for time t0 if t0 is in a weekday, or associate a comparatively lower probability density value for time t0 if t0 is in a weekend day.

Transition probability density 602 can be discrete or continuous. Upon determining transition probability density 602 and other transition probability densities between states of state model 104, mobile device 102 can determine a time-based likelihood of mobile device 102 transitioning from a current state (e.g., state 106) to each other state directly or indirectly (e.g., through one or more intermediate states). Mobile device 102 can determine a predicted future location of mobile device 102 based on the current location, the future time, and the probabilities of mobile device 102 transitioning to each state.

FIG. 6B is diagram illustrating determining entry probability density 620 of exemplary state 106. Entry probability density 620 can indicate a probability distribution that mobile device 102 enters state 106 from a current location that is not represented in state model 104. Mobile device 102 can determine entry probability density 620 upon receiving a request to predict a future location of mobile device 102. The request can be associated with a current time and a future time. At the current time, mobile device 102 can be located at the un-represented current location. The future time can be a point in time or a time window.

Entry probability density 620 can be a distribution over a time period, e.g., [Tc, Td], where Tc is a starting time, and Td is an ending time of the time period. The time period [Tc, Td] can be a window of forecast. In some implementations, the starting time Tc can correspond to the current time, or the current time with a bias (e.g., X minutes before or after the current time); the ending time Td can correspond to the future time, or the future time with a bias (e.g., Y minutes before or after the future time). In some implementations, the starting time Tc and ending time Td can correspond to a beginning and ending of a time window (e.g., a day or a week), respectively.

Mobile device 102 can determine entry probability density 620 based on dwell time of mobile device 102 in state 106. The dwell time, e.g., dwell time 412, 414, and 622, can be determined as described above in reference to FIG. 4.

At a given time between Tc and Td, (1) more number of stays of mobile device 102 in state 106 in the past at the given time can correspond to a higher probability density value; (2) more certainty on the entry into the state 106 in the past can correspond to a higher probability density value; and (3) a more stable pattern of entry into state 106 in the past can correspond to a higher probability density value.

For example, t2 corresponds to 10:00 am, and t2 corresponds to 3:00 pm. In the past, and as recorded in state model 104 by dwell time 412, 414, and 622, on X number occasions, mobile device 102 is located in state 106 at time t2; and on Y number occasions, mobile device 102 is in state 106 at time t3. If X is less than Y (e.g., in this example, X=2, Y=3), t2 can correspond to comparatively lower probability density value 624, whereas t3 can correspond to comparatively lower probability density value 626.

Additionally or alternatively, mobile device 102 can determine, based on state dwelling time determined from state model 104, that location of mobile device 102 follows a weekly pattern. For example, mobile device 102 can determine that dwell time 414, and a number of other dwell times occur only on weekdays, whereas dwell times 412 and 622 occur only on weekends. Based on this identified weekly pattern, mobile device 102 can associate lower probability density value 624 to time t2 and higher probability density value 624 to time t3 if time t2 and time t3 fall on a weekday. Mobile device 102 can associate equal probability density values to time t2 and time t3 fall on a weekend day.

Entry probability density 620 can be discrete or continuous. Upon determining entry probability density 620 and other entry probability densities between states of state model 104, mobile device can determine a time-based likelihood of mobile device 102 enters from a current location to each other state directly or indirectly (e.g., through one or more intermediate states). Mobile device 102 can determine a predicated future location of mobile device 102 based on the current location, the future time, and the probabilities of mobile device 102 entering each state.

Mobile device 102 can filter out states from state model 104 before, during, or after calculating the entry probability densities based on various factors. Filtering out a state can include preventing the state being used for a particular location prediction without removing the state from state model 104. The factors for filtering out a state can include a distance between the current location and the location represented by the state in state model 104. Mobile device 102 can filter out a state upon determining that, during the forecast time window, mobile device 102 is unlikely to reach from the current location to the location of that state. Mobile device can perform the filtering based on a time difference between the current time and the starting time or the ending time of the time window, and a pre-specified maximum speed of movement of mobile device 102.

For example, mobile device 102 can determine that the time difference between the current time and the closing time Td of the forecasting time window is X hours. Mobile device can determine that a distance between the current location and the significant location represented by state 106 is Y kilometers. Based on a pre-specified maximum speed of Z kilometers per hour, mobile device 102 can filter out state 106 upon determining that X*Z<Y, indicating that mobile device 102 cannot reach the location represented by state 106 in X hours, even if travelling at maximum speed.

Exemplary Device Components

FIG. 7A is a block diagram illustrating components of exemplary mobile device 102 implementing predictive user assistance. Each component of mobile device 102 can include hardware and software components.

Mobile device 102 can include state model determination subsystem 702. State model determination subsystem 702 can be a component of mobile device 102 programmed to determining a state model (e.g., state model 104) using location data from location determination subsystem 704. The location data can include a series of one or more location readings, each being associated with a timestamp. The location readings can include latitude, longitude, and optionally, altitude coordinates.

Location determination subsystem 704 is a component of mobile device 102 programmed to determine a location of mobile device 102 using a satellite navigation system (e.g., GPS), a cellular communications system (e.g., by triangulation using cellular towers), or wireless access gateways (e.g., by triangulation using known access point locations).

Mobile device 102 can include one or more services 706. Services 706 can include functions of an operating system of mobile device 102 or one or more application programs. Services 706 can request location data from location determination subsystem 704. The request can activate location determination subsystem 704.

State model determination subsystem 702 can be configured to read location data provided by location determination subsystem 704 upon activation of location determination subsystem 704 by services 706. Triggering reading location data by activation of location determination subsystem 704 can avoid or minimize consumption of battery power by operations of determining the state model. Based on the location data, state model determination subsystem 702 can determine a state model and store the state model in state model database 708. State model database 708 can include a storage device on mobile device 102 or on a server located remotely from mobile device 102.

Mobile device 102 can include forecasting subsystem 710. Forecasting subsystem 710 is a component of mobile device 102 configured to determine a predicted future location of mobile device 102 based on the state model stored in state model database 708. One or more services 712 or other devices 714 can request a forecast from forecasting subsystem 710. The request can be associated with a future time point or time window. In response, forecasting subsystem 710 can provide one or more predicted future locations corresponding to the future time or time window.

FIG. 7B is a block diagram illustrating components of exemplary state model determination subsystem 702 of FIG. 7A. Each component of state model determination subsystem 702 can include hardware and software components.

State model determination subsystem 702 can include location listener 720. Location listener 720 is a component of state model determination subsystem 702 configured to read location data from location determination subsystem 704 upon being triggered by an activation of location determination subsystem 704. In some implementations, location listener 720 can be programmed to activate location determination subsystem 704 periodically to obtain the location data.

Location listener 720 can store the location data received from location determination subsystem 704 to raw location data store 722. Raw location data store 722 can be a storage device of mobile device 102 programmed to store raw location data as read from location determination subsystem 704. Raw location data store 722 can enforce a persistency policy where the raw location data are purged after a specified persistency period based on user request or privacy policy.

State model determination subsystem 702 can include abstraction engine 724. Abstraction engine 724 is a component of state model determination subsystem 702 configured to access the location data stored in raw location data store 722. Based on the location data, abstraction engine 724 can determine location clusters based on one or more pre-specified conditions. The conditions can include a minimum number of locations for establishing a significant location (e.g., two), a threshold time window (e.g., minimum of X minutes), and outlier criteria. Abstraction engine 724 can determine the significant locations by generating abstractions of the location clusters. Abstraction engine 724 can store the significant locations in location data store 726.

Location data store 726 is a storage device of state model determination subsystem 702 configured to store significant locations determined by abstraction engine 724. Location data store 726 can enforce a persistency policy where the significant locations are purged after a specified persistency period. The persistence policy for location data store 726 can be different from the persistence policy for raw location data store 722.

State model determination subsystem 702 can include state model construction engine 728. State model construction engine 728 is a component of state model determination subsystem 702 configured to read the significant locations from location data store 726, and generate state model 104. In addition, state model construction engine 728 can be configured to maintain state model 104 by adding and removing states to state model 104.

FIG. 7C is a block diagram illustrating components of exemplary forecasting subsystem 710 of FIG. 7A. Each component of forecasting subsystem 710 can include hardware and software components.

Forecasting subsystem 710 can include probability modeler 740. Probability modeler 740 is a component of forecasting subsystem 710 configured to determine probability densities (e.g., transition probability density 602 and entry probability density 620) based on states and transitions of a state model (e.g., state model 104). Probability modeler 740 can determine the probability densities for transitions and entries over a time window.

Forecasting subsystem 710 can include pattern analyzer 742. Pattern analyzer 742 is a component of forecasting subsystem 710 configured to determine a pattern of movement of mobile device 102 over a time period. The time period can be a day, a week, a month, or a year. Pattern analyzer 742 can determine whether to determine a pattern based on a day, a week, a month, or a year based on a longevity of state model 104. For example, pattern analyzer 742 can determine whether state model 104 has satisfied a longevity threshold (e.g., contains at least X weeks of data).

Upon determining that state model 104 satisfies the threshold, pattern analyzer 742 can determine a weekly pattern. The weekly pattern can include a probability distribution calculated for each day of week, where, for example, a probability distribution for Monday is determined separately from a probability distribution for Sunday. Upon determining that state model 104 does not satisfy the threshold, pattern analyzer 742 can determine a daily pattern. The daily pattern can include a probability distribution calculated for each hour of day, where, for example, a probability distribution for 9:00 am to 10:00 am is determined separately from a probability distribution for 5:00 pm to 6:00 pm.

In some implementations, pattern analyzer 742 can determine a daily pattern upon determining that mobile device 102 has moved to a new place. For example, pattern analyzer 742 can determine that, the distances between each of the last X number of new states and each state older than the last X number of new states exceed a local threshold (e.g., Y kilometers), indicating that mobile device 102 has recently travelled to a new location (e.g., to a vacation place). Upon the determination, pattern analyzer 742 can determine the daily pattern, starting from the last X number of states.

Forecasting subsystem 710 can include prediction engine 744. Prediction engine 744 is a component of forecasting subsystem 710 configured to receive a current time and a current location and determine a forecast location. Prediction engine 744 can determine a predicted location of mobile device 102 based on the probability densities for transitions and entries provided by probability modeler 740 and the movement patterns provided from pattern analyzer 742. Prediction engine 744 can identify multiple candidate future locations based on the probability densities and the movement patterns. Prediction engine 744 can then rank the candidate future locations using various attributes.

The attributes used by prediction engine 744 to rank the candidate future locations can include a last visit to a candidate future location as represented by a state, where a more recent visit can be associated with a higher ranking. The attributes can include a data longevity of the state associated with the candidate location, where a state having a longer data history can be associated with a higher ranking. The attribute can include a likelihood associated with a forecast time window, which is determined based on a current location, a future time of the forecast time window, and a length of the forecast time window. The attributes can include an aggregated dwell time, where a state having longer aggregated dwell time can be ranked higher. The attributes can include a number of visits to the state of the candidate location, where more visits or a higher frequency of visits to the state can be ranked higher. Prediction engine 744 can provide one or more candidate future locations, including the highest ranked candidate future location, to prediction engine interface 746 as a forecast.

Prediction engine interface 746 can be a component of mobile device 102 configured to implement an application programming interface (API) to prediction engine 744 such that an application program, function, or device complying with the API can access the forecast determined by prediction engine 744. In some implementations, prediction engine interface 746 can include an interface to other devices 714, e.g., external display screens or GPS devices, and provide the forecast location to other devices 714.

Forecasting subsystem 710 can include semantic analyzer 748. Semantic analyzer 748 is a component of forecasting subsystem 710 configured to determine a meaning of each significant location based on pattern of visit to the significant location. Semantic analyzer 748 can generate labels (e.g., “work” or “home”) based on the meaning and provide the labels to prediction engine interface 746 to be associated with the forecast.

Exemplary Procedures

FIG. 8 is a flowchart illustrating exemplary procedure 800 of generating a state model 104. Procedure 800 can be performed by mobile device 102.

Mobile device 102 can receive (802), from location determination subsystem 704 of mobile device 102, multiple locations of mobile device 102. Each location can be associated with a timestamp indicating a time the location was determined by location determination subsystem 704. The locations can be ordered sequentially based on timestamps of the locations. Receiving the locations can include reading the location from location determination subsystem 704 one at a time. Each reading of location determination subsystem 704 can be triggered by an activation of location determination subsystem 704 by an application program or function external to a location forecasting application program or function.

Mobile device 102 can determine (804), based on a clustering condition, that two or more consecutive locations in the ordered locations form a location cluster. The location cluster can indicate that mobile device 102 has stayed at a geographic location that is sufficiently significant to be represented in a state model for forecasting a movement of mobile device 102. The clustering condition can specify that, to be designated as a location cluster, the consecutive locations are identical, or a distance between each pair of the consecutive locations is less than a spatial proximity threshold. In addition, the clustering condition can specify that, to be designated as a location cluster, a time difference between a timestamp associated with a first location among the consecutive locations and a timestamp associated with a last location among the consecutive locations is greater than a temporal proximity threshold (e.g., X minutes). The geographic location can be designated as a significant location, which is a location where mobile device 102 has stayed for a time period at least as long as indicated by the temporal proximity threshold.

In some implementations, determining the location cluster can include validating each of the two or more consecutive locations based on an uncertainty value associated with each respective location. The uncertainty value can indicate a likelihood that the respective location is determined correctly by location determination subsystem 704. Mobile device 102 can exclude one or more outliers from the consecutive locations. Each outlier can be a location associated with an uncertainty value that exceeds a threshold. Mobile device 102 can then determine the location cluster using the validated locations that are not outliers.

In some implementations, a significant location can correspond to multiple location clusters (e.g., a first location cluster on Monday and a second location cluster on Tuesday). Each location cluster may include locations that are different from one another. Mobile device 102 can determine the significant location based on one or more location clusters corresponding to the significant location by applying a recursive filter having a constant gain to locations in each location cluster.

Mobile device 102 can determine (806), based on the location cluster, the state model (e.g., state model 104). Mobile device 102 can designate the significant location as a state in the state model. Mobile device 102 can represent each movement of mobile device 102 from a first significant location to a second significant location as a transition from a first state representing the first significant location to a second state representing the second significant location. The transition can be associated with a transition start time and a transition end time. Each state can be associated with one or more state entry timestamps and one or more state exit timestamps.

Determining the state model can include adding a state or adjusting a state. Upon determining that a location cluster is not already designated as a state in the state model, mobile device 102 can add the location cluster to the state model as a new state. Upon determining that the location cluster is already represented as a state in the state model, mobile device 102 can adjust the state, including adding a transition to or from the state, or adding a new state entry time and state exit time to the state.

Mobile device 102 can provide (808) the state model to forecasting subsystem 710 of mobile device 102 for generating a forecast. The forecast can include a prediction that a future location of mobile device 102, at a given future time, is one of the significant locations represented in the state model. Forecasting subsystem 710 can generate the forecast based on a current time, the future time, a current location, and a probability density determined based on the states and transitions of the state model.

In some implementations, mobile device 102 can determine (810) a semantic meaning of each state of the state model. Mobile device 102 can determine that at least one attribute of the state model satisfies a statistical threshold, and then determine a semantic meaning of the state and a semantic meaning of the transition. The statistical threshold can include a longevity of the state. Determining the semantic meaning of the state comprises determining whether the state relates to an activity pattern of life (e.g., a pattern of a person going to work or going home). Determining the semantic meaning of the transition can be based an attribute of a commute between two activities of life.

For example, mobile device 102 can determine that during weekday mornings, mobile device 102 usually travels from significant location A to significant location B; that during weekday evenings, mobile device 102 usually travels from significant location B to significant location A; and that during weekends, mobile device 102 is sometimes located at location A, but never located at location B. Upon the determination, mobile device 102 can designate location A as “home” and location B as “work” and provide the designations as labels of predicted locations to an application program requesting a forecast.

In some implementations, mobile device 102 can adjust states in the state model over time using an autoregressive filter. Adjusting the states includes removing a stale state from the state model upon determining that the mobile device has not visited a significant location represented by the stale model for a given period of time.

FIG. 9 is a flowchart illustrating exemplary procedure 900 of predicting a future location. Procedure 900 can be performed by mobile device 102, for example, using forecasting subsystem 710 of mobile device 102.

Mobile device 102 can receive (902), from a storage device (e.g., state model database 708) coupled to mobile device 102, a state model. The state model can include multiple states and transitions between the states. Each state can correspond to a location. Each transition from a first state to a second state can indicate that, in the past, mobile device 102 moved from a corresponding first location to a corresponding second location. Each location and transition can be associated with one or more timestamps.

Mobile device 102 can receive (904), from an application program or a device, a request for predicting a future location of mobile device 102. The request can specify a future time and, optionally, a current location of mobile device 102. The future time can include a point in time in the future or a time window in the future.

Mobile device 102 can determine (906), using a current time, the future time, and a current location of the mobile device as inputs, a probability for associating with each state in the state model. If the request does not include the current location, mobile device 102 can determine the current location using location determination subsystem 704. Mobile device 102 can determine the probabilities based on the states, transitions, and associating timestamps. The probabilities can indicate a likelihood that mobile device 102 will be located at each respective location corresponding to a state at the future time.

Determining (906) the probability for associating with each state can include determining that the current location is in state, where the current location is represented as a state in the state model. Determining the probability for each state can include determining a transition probability density of mobile device 102 moving from the state representing current location to a location corresponding to the state in one or more transitions. The transition probability density can satisfy properties of a Markov process. Determining the transition probability density can be based on the transitions between states and a transition begin timestamp and a transition end timestamp associated with each of the transitions.

Determining (906) the probability for associating with each state can include determining that the current location is out of state, where the current location is not represented as a state in the state model. Determining the probability to be associated with each state can include determining an entry probability density of mobile device 102 entering a location corresponding to each state from the out-of-state current location. Determining the entry probability density can be based on a dwell time mobile device 102 is in each state. Mobile device 102 can determine the dwell time based on one or more entry timestamps and one or more exit timestamps associated with the respective state.

In some implementations, determining (906) the probability for associating with each state can be based on a daily, weekly, monthly, or annual pattern. Mobile device 102 can determine whether the state model satisfies a longevity threshold (e.g., X weeks). Mobile device 102 can determine a first activity pattern upon determining the state model satisfies the longevity threshold. The first activity pattern can correspond to a first time span (e.g., a week). Alternatively, mobile device 102 can determine a second activity pattern upon determining that the state model does not satisfy the longevity threshold. The second activity pattern can correspond to a second time span (e.g., a day). The first time span can be longer than the second time span. Mobile device 102 can determine the probability based on the current time, the future time, and the first activity pattern or second activity pattern. Mobile device 102 can then determine the probability for associating with each state based on the current time, the future time, and the first activity pattern or second activity pattern.

In some implementations, mobile device 102 can filter the states in the state model based on a distance between the current location and each location represented in the state model and a difference between the current time and the future time. Mobile device 102 can filter out the states that, given the difference in time, and given a moving speed of mobile device 102, a likelihood that mobile device 102 reaches the state from the current location falls below a threshold value.

Based on the probabilities, mobile device 102 can provide (908) at least one location associated with a state as a predicted future location of mobile device 102 in response to the request. In some implementations, providing the location as the predicted future location can include identifying a state associated with a highest probability, and designating the location associated with the state associated with the highest probability as the predicted future location. In some implementations, providing the location as the predicted future location can include ranking the states based on the probabilities and one or more forecast attributes, and designating the location associated with a highest rank as the predicted future location.

The forecast attributes can include a time of last visit to each corresponding location. The forecast attributes can include a derived likelihood for a forecast window based on the current location, the current time, and a forecast window length. The forecast attributes can include a temporal length of the state model. The forecast attributes can include an aggregated dwell time at each state. The forecast attributes can include a number of visits at each state.

In some implementations, mobile device 102 can determine that a data density of the state model satisfies a sparse model threshold. In response, mobile device 102 can determine the probability for associating with each state in a sparse operating mode. In the sparse operating mode, probability density calculations and rankings can be performed in a less stringent matter than the calculations and rankings in normal operating mode.

Exemplary Mobile Device Architecture

FIG. 10 is a block diagram illustrating exemplary device architecture 1000 of a mobile device implementing the features and operations of category-based geofence. A mobile device (e.g., mobile device 102) can include memory interface 1002, one or more data processors, image processors and/or processors 1004, and peripherals interface 1006. Memory interface 1002, one or more processors 1004 and/or peripherals interface 1006 can be separate components or can be integrated in one or more integrated circuits. Processors 1004 can include application processors, baseband processors, and wireless processors. The various components in mobile device 102, for example, can be coupled by one or more communication buses or signal lines.

Sensors, devices, and subsystems can be coupled to peripherals interface 1006 to facilitate multiple functionalities. For example, motion sensor 1010, light sensor 1012, and proximity sensor 1014 can be coupled to peripherals interface 1006 to facilitate orientation, lighting, and proximity functions of the mobile device. Location processor 1015 (e.g., GPS receiver) can be connected to peripherals interface 1006 to provide geopositioning. Electronic magnetometer 1016 (e.g., an integrated circuit chip) can also be connected to peripherals interface 1006 to provide data that can be used to determine the direction of magnetic North. Thus, electronic magnetometer 1016 can be used as an electronic compass. Motion sensor 1010 can include one or more accelerometers configured to determine change of speed and direction of movement of the mobile device. Barometer 1017 can include one or more devices connected to peripherals interface 1006 and configured to measure pressure of atmosphere around the mobile device.

Camera subsystem 1020 and an optical sensor 1022, e.g., a charged coupled device (CCD) or a complementary metal-oxide semiconductor (CMOS) optical sensor, can be utilized to facilitate camera functions, such as recording photographs and video clips.

Communication functions can be facilitated through one or more wireless communication subsystems 1024, which can include radio frequency receivers and transmitters and/or optical (e.g., infrared) receivers and transmitters. The specific design and implementation of the communication subsystem 1024 can depend on the communication network(s) over which a mobile device is intended to operate. For example, a mobile device can include communication subsystems 1024 designed to operate over a GSM network, a GPRS network, an EDGE network, a Wi-Fi™ or WiMAX™ network, and a Bluetooth™ network. In particular, the wireless communication subsystems 1024 can include hosting protocols such that the mobile device can be configured as a base station for other wireless devices.

Audio subsystem 1026 can be coupled to a speaker 1028 and a microphone 1030 to facilitate voice-enabled functions, such as voice recognition, voice replication, digital recording, and telephony functions. Audio subsystem 1026 can be configured to receive voice commands from the user.

I/O subsystem 1040 can include touch surface controller 1042 and/or other input controller(s) 1044. Touch surface controller 1042 can be coupled to a touch surface 1046 or pad. Touch surface 1046 and touch surface controller 1042 can, for example, detect contact and movement or break thereof using any of a plurality of touch sensitivity technologies, including but not limited to capacitive, resistive, infrared, and surface acoustic wave technologies, as well as other proximity sensor arrays or other elements for determining one or more points of contact with touch surface 1046. Touch surface 1046 can include, for example, a touch screen.

Other input controller(s) 1044 can be coupled to other input/control devices 1048, such as one or more buttons, rocker switches, thumb-wheel, infrared port, USB port, and/or a pointer device such as a stylus. The one or more buttons (not shown) can include an up/down button for volume control of speaker 1028 and/or microphone 1030.

In one implementation, a pressing of the button for a first duration may disengage a lock of the touch surface 1046; and a pressing of the button for a second duration that is longer than the first duration may turn power to mobile device 102 on or off. The user may be able to customize a functionality of one or more of the buttons. The touch surface 1046 can, for example, also be used to implement virtual or soft buttons and/or a keyboard.

In some implementations, mobile device 102 can present recorded audio and/or video files, such as MP3, AAC, and MPEG files. In some implementations, mobile device 102 can include the functionality of an MP3 player. Mobile device 102 may, therefore, include a pin connector that is compatible with the iPod. Other input/output and control devices can also be used.

Memory interface 1002 can be coupled to memory 1050. Memory 1050 can include high-speed random access memory and/or non-volatile memory, such as one or more magnetic disk storage devices, one or more optical storage devices, and/or flash memory (e.g., NAND, NOR). Memory 1050 can store operating system 1052, such as Darwin, RTXC, LINUX, UNIX, OS X, WINDOWS, iOS, or an embedded operating system such as VxWorks. Operating system 1052 may include instructions for handling basic system services and for performing hardware dependent tasks. In some implementations, operating system 1052 can include a kernel (e.g., UNIX kernel).

Memory 1050 may also store communication instructions 1054 to facilitate communicating with one or more additional devices, one or more computers and/or one or more servers. Memory 1050 may include graphical user interface instructions 1056 to facilitate graphic user interface processing; sensor processing instructions 1058 to facilitate sensor-related processing and functions; phone instructions 1060 to facilitate phone-related processes and functions; electronic messaging instructions 1062 to facilitate electronic-messaging related processes and functions; web browsing instructions 1064 to facilitate web browsing-related processes and functions; media processing instructions 1066 to facilitate media processing-related processes and functions; GPS/Navigation instructions 1068 to facilitate GPS and navigation-related processes and instructions; camera instructions 1070 to facilitate camera-related processes and functions; magnetometer data 1072 and calibration instructions 1074 to facilitate magnetometer calibration. The memory 1050 may also store other software instructions (not shown), such as security instructions, web video instructions to facilitate web video-related processes and functions, and/or web shopping instructions to facilitate web shopping-related processes and functions. In some implementations, the media processing instructions 1066 are divided into audio processing instructions and video processing instructions to facilitate audio processing-related processes and functions and video processing-related processes and functions, respectively. An activation record and International Mobile Equipment Identity (IMEI) or similar hardware identifier can also be stored in memory 1050. Memory 1050 can store predictive user assistance instructions 1076 that include modeling instructions and forecasting instructions. The modeling instructions, upon execution, can cause processor 1004 to perform the operations of state model determination subsystem 702, including procedure 800. The forecasting instructions, upon execution, can cause processor 1004 to perform the operations of forecasting subsystem 710. The operations can include procedure 900.

Each of the above identified instructions and applications can correspond to a set of instructions for performing one or more functions described above. These instructions need not be implemented as separate software programs, procedures, or modules. Memory 1050 can include additional instructions or fewer instructions. Furthermore, various functions of the mobile device may be implemented in hardware and/or in software, including in one or more signal processing and/or application specific integrated circuits.

Exemplary Operating Environment

FIG. 11 is a block diagram of exemplary network operating environment 1100 for the mobile devices implementing the features and operations of category-based geofence. Mobile devices 1102 a and 1102 b can, for example, communicate over one or more wired and/or wireless networks 1110 in data communication. For example, a wireless network 1112, e.g., a cellular network, can communicate with a wide area network (WAN) 1114, such as the Internet, by use of a gateway 1116. Likewise, an access device 1118, such as an 802.11g wireless access point, can provide communication access to the wide area network 1114. Each of mobile devices 1102 a and 1102 b can be mobile device 102.

In some implementations, both voice and data communications can be established over wireless network 1112 and the access device 1118. For example, mobile device 1102 a can place and receive phone calls (e.g., using voice over Internet Protocol (VoIP) protocols), send and receive e-mail messages (e.g., using Post Office Protocol 3 (POP 3)), and retrieve electronic documents and/or streams, such as web pages, photographs, and videos, over wireless network 1112, gateway 1116, and wide area network 1114 (e.g., using Transmission Control Protocol/Internet Protocol (TCP/IP) or User Datagram Protocol (UDP)). Likewise, in some implementations, the mobile device 1102 b can place and receive phone calls, send and receive e-mail messages, and retrieve electronic documents over the access device 1118 and the wide area network 1114. In some implementations, mobile device 1102 a or 1102 b can be physically connected to the access device 1118 using one or more cables and the access device 1118 can be a personal computer. In this configuration, mobile device 1102 a or 1102 b can be referred to as a “tethered” device.

Mobile devices 1102 a and 1102 b can also establish communications by other means. For example, wireless device 1102 a can communicate with other wireless devices, e.g., other mobile devices, cell phones, etc., over the wireless network 1112. Likewise, mobile devices 1102 a and 1102 b can establish peer-to-peer communications 1120, e.g., a personal area network, by use of one or more communication subsystems, such as the Bluetooth™ communication devices. Other communication protocols and topologies can also be implemented.

Mobile device 1102 a or 1102 b can, for example, communicate with one or more services 1130 and 1140 over the one or more wired and/or wireless networks. For example, one or more location services 1130 can provide location data associated with cellular towers or wireless access gateways to mobile devices 1102 a and 1102 b such that mobile device 1102 a and 1102 b can determine a current location using triangulation. Traffic services 1140 can provide traffic information based on a current time, current location, and a forecast location to assist a user planning a route to the forecast location.

Mobile device 1102 a or 1102 b can also access other data and content over the one or more wired and/or wireless networks. For example, content publishers, such as news sites, Really Simple Syndication (RSS) feeds, web sites, blogs, social networking sites, developer networks, etc., can be accessed by mobile device 1102 a or 1102 b. Such access can be provided by invocation of a web browsing function or application (e.g., a browser) in response to a user touching, for example, a Web object.

As described above, some aspects of the subject matter of this specification include gathering and use of data available from various sources to improve services a mobile device can provide to a user. The present disclosure contemplates that in some instances, this gathered data may include personal information data that uniquely identifies or can be used to contact or locate a specific person. Such personal information data can include demographic data, location-based data, telephone numbers, email addresses, twitter ID's, home addresses, or any other identifying information.

The present disclosure recognizes that the use of such personal information data, in the present technology, can be used to the benefit of users. For example, the personal information data can be used to deliver targeted content that is of greater interest to the user. Accordingly, use of such personal information data enables calculated control of the delivered content. Further, other uses for personal information data that benefit the user are also contemplated by the present disclosure.

The present disclosure further contemplates that the entities responsible for the collection, analysis, disclosure, transfer, storage, or other use of such personal information data will comply with well-established privacy policies and/or privacy practices. In particular, such entities should implement and consistently use privacy policies and practices that are generally recognized as meeting or exceeding industry or governmental requirements for maintaining personal information data private and secure. For example, personal information from users should be collected for legitimate and reasonable uses of the entity and not shared or sold outside of those legitimate uses. Further, such collection should occur only after receiving the informed consent of the users. Additionally, such entities would take any needed steps for safeguarding and securing access to such personal information data and ensuring that others with access to the personal information data adhere to their privacy policies and procedures. Further, such entities can subject themselves to evaluation by third parties to certify their adherence to widely accepted privacy policies and practices.

Despite the foregoing, the present disclosure also contemplates embodiments in which users selectively block the use of, or access to, personal information data. That is, the present disclosure contemplates that hardware and/or software elements can be provided to prevent or block access to such personal information data. For example, in the case of advertisement delivery services, the present technology can be configured to allow users to select to “opt in” or “opt out” of participation in the collection of personal information data during registration for services.

Therefore, although the present disclosure broadly covers use of personal information data to implement one or more various disclosed embodiments, the present disclosure also contemplates that the various embodiments can also be implemented without the need for accessing such personal information data. That is, the various embodiments of the present technology are not rendered inoperable due to the lack of all or a portion of such personal information data. For example, content can be selected and delivered to users by inferring preferences based on non-personal information data or a bare minimum amount of personal information, such as the content being requested by the device associated with a user, other non-personal information available to the content delivery services, or publically available information.

A number of implementations of the invention have been described. Nevertheless, it will be understood that various modifications can be made without departing from the spirit and scope of the invention. 

What is claimed is:
 1. A method comprising: receiving, by a mobile device and from a storage device coupled to the mobile device, a state model, the state model comprising a plurality of states and transitions between the states, each state corresponding to a location, each transition from a first state to a second state indicating that the mobile device moved from a corresponding first location to a corresponding second location, each state and each transition being associated with a one or more timestamps; receiving, by the mobile device, a request for predicting a future location of the mobile device, the request specifying a future time; determining, using a current time, the future time, and a current location of the mobile device as inputs, and based on a time period associated with the state model, and the states, transitions and associated timestamps in the state model, a probability for associating with each state, the time period corresponding to a length of time for which the state machine contains location data, and the probability indicating a likelihood that the mobile device will be located at the location corresponding to the state at the future time; and based on the probabilities, providing a location associated with at least one state as a predicted future location in response to the request.
 2. The method of claim 1, wherein determining the probability for associating with each state comprises: determining that the current location is in state, where the current location is represented as a state in the state model.
 3. The method of claim 2, wherein determining the probability for associating with each state comprises determining a transition probability density of the mobile device moving from the current location to a location corresponding to the each state in one or more transitions.
 4. The method of claim 3, wherein: the transition probability density satisfies properties of a Markov process, and determining the transition probability density is based on the transitions between states and a transition begin timestamp and a transition end timestamp associated with each of the transitions.
 5. The method of claim 1, wherein determining the probability for each state comprises: determining that the current location is out of state, where the current location is not represented as a state in the state model.
 6. The method of claim 5, wherein determining the probability to be associated with each state comprises determining an entry probability density of the mobile device entering a location corresponding to the each state.
 7. The method of claim 6, wherein determining the entry probability density is based on a dwell time the mobile device is in each state, the dwell time being determined based on one or more entry timestamps and one or more exit timestamps associated with the respective state.
 8. The method of claim 1, wherein determining the probability for associating with each state comprises: determining whether the time period associated with the state model satisfies a longevity threshold; determining a first activity pattern upon determining that the time period associated with the state model satisfies the longevity threshold, wherein the first activity pattern corresponds to a first time span, or determining a second activity pattern upon determining that the time period associated with the state model does not satisfy the longevity threshold, wherein the second activity pattern corresponds to a second time span, the first time span being longer than the second time span; and determining the probability based on the current time, the future time, and the first activity pattern or second activity pattern.
 9. The method of claim 1, comprising filtering the states in the state model based on a distance between the current location and each location represented in the state model and a difference between the current time and the future time.
 10. The method of claim 1, wherein providing the location as the predicted future location comprises: identifying a state associated with a highest probability, and designating the location associated with the state associated with the highest probability as the predicted future location; or ranking the states based on the probabilities and one or more forecast attributes, and designating the location associated with a highest rank as the predicted future location.
 11. The method of claim 10, wherein forecast attributes include at least one of: a time of last visit to each corresponding location; a derived likelihood for a forecast window based on the current location, the current time, and a forecast window length; a temporal length of the state model; an aggregated dwell time at each state; or a number of visits at each state.
 12. The method of claim 1, comprising: determining that a data density of the state model satisfies a sparse model threshold; and in response, determining the probability for associating with each state in a sparse operating mode.
 13. A system comprising: one or more processors; a non-transitory storage device storing instructions operable to cause the one or more processors to perform operations comprising: receiving, by a mobile device and from a storage device coupled to the mobile device, a state model, the state model comprising a plurality of states and transitions between the states, each state corresponding to a location, each transition from a first state to a second state indicating that the mobile device moved from a corresponding first location to a corresponding second location, each state and each transition being associated with a one or more timestamps; receiving, by the mobile device, a request for predicting a future location of the mobile device, the request specifying a future time; determining, using a current time, the future time, and a current location of the mobile device as inputs, and based on a time period associated with the state model, and the states, transitions and associated timestamps in the state model, a probability for associating with each state, the time period corresponding to a length of time for which the state machine contains location data, and the probability indicating a likelihood that the mobile device will be located at the location corresponding to the state at the future time; and based on the probabilities, providing a location associated with at least one state as a predicted future location in response to the request.
 14. The system of claim 13, wherein determining the probability for associating with each state comprises: determining that the current location is in state, where the current location is represented as a state in the state model.
 15. The system of claim 14, wherein determining the probability for associating with each state comprises determining a transition probability density of the mobile device moving from the current location to a location corresponding to the each state in one or more transitions.
 16. The system of claim 15, wherein: the transition probability density satisfies properties of a Markov process, and determining the transition probability density is based on the transitions between states and a transition begin timestamp and a transition end timestamp associated with each of the transitions.
 17. The system of claim 13, wherein determining the probability for each state comprises: determining that the current location is out of state, where the current location is not represented as a state in the state model.
 18. The system of claim 17, wherein determining the probability to be associated with each state comprises determining an entry probability density of the mobile device entering a location corresponding to the each state.
 19. The system of claim 18, wherein determining the entry probability density is based on a dwell time the mobile device is in each state, the dwell time being determined based on one or more entry timestamps and one or more exit timestamps associated with the respective state.
 20. A non-transitory storage device storing instructions operable to cause one or more processors to perform operations comprising: receiving, by a mobile device and from a storage device coupled to the mobile device, a state model, the state model comprising a plurality of states and transitions between the states, each state corresponding to a location, each transition from a first state to a second state indicating that the mobile device moved from a corresponding first location to a corresponding second location, each state and each transition being associated with a one or more timestamps; receiving, by the mobile device, a request for predicting a future location of the mobile device, the request specifying a future time; determining, using a current time, the future time, and a current location of the mobile device as inputs, and based on a time period associated with the state model, and the states, transitions and associated timestamps in the state model, a probability for associating with each state, the time period corresponding to a length of time for which the state machine contains location data, and the probability indicating a likelihood that the mobile device will be located at the location corresponding to the state at the future time; and based on the probabilities, providing a location associated with at least one state as a predicted future location in response to the request. 